{"ast":null,"code":"import _slicedToArray from\"/Users/poppie/Desktop/development/messenger/app/frontend/node_modules/@babel/runtime/helpers/esm/slicedToArray.js\";import React from'react';import{Controller,useForm,useFormState}from\"react-hook-form\";import{nicknameChangeValidation,firstNameChangeValidation,lastNameChangeValidation,passwordChangeValidation,confirmChangePassword}from'../../validation';import Typography from\"@mui/material/Typography\";import TextField from\"@mui/material/TextField\";import AlternateEmailOutlinedIcon from\"@mui/icons-material/AlternateEmailOutlined\";import VpnKeyOutlinedIcon from\"@mui/icons-material/VpnKeyOutlined\";import Button from\"../../../components/Button\";import Switch from'@mui/material/Switch';import BadgeOutlinedIcon from'@mui/icons-material/BadgeOutlined';import{Context}from\"../../../index\";import{observer}from\"mobx-react-lite\";import styles from\"../../Form.module.scss\";import\"./ChangeProfileForm.scss\";import{jsx as _jsx}from\"react/jsx-runtime\";import{jsxs as _jsxs}from\"react/jsx-runtime\";var ChangeProfileForm=function ChangeProfileForm(_ref){var profile=_ref.profile,cancel=_ref.cancel;var _React$useContext=React.useContext(Context),store=_React$useContext.store;var _useForm=useForm(),handleSubmit=_useForm.handleSubmit,control=_useForm.control,watch=_useForm.watch;var _useFormState=useFormState({control:control}),errors=_useFormState.errors;var _React$useState=React.useState(false),_React$useState2=_slicedToArray(_React$useState,2),switchEmail=_React$useState2[0],setSwitchEmail=_React$useState2[1];var _React$useState3=React.useState(profile.nickname),_React$useState4=_slicedToArray(_React$useState3,2),fieldDefaultNickName=_React$useState4[0],setFieldDefaultNickName=_React$useState4[1];var _React$useState5=React.useState(profile.firstName||''),_React$useState6=_slicedToArray(_React$useState5,2),fieldDefaultFirstName=_React$useState6[0],setFieldDefaultFirstName=_React$useState6[1];var _React$useState7=React.useState(profile.lastName||''),_React$useState8=_slicedToArray(_React$useState7,2),fieldDefaultLastName=_React$useState8[0],setFieldDefaultLastName=_React$useState8[1];React.useEffect(function(){profile.hideEmail&&setSwitchEmail(profile.hideEmail);},[profile]);var onSubmit=function onSubmit(data){var _data$nickname,_data$password,_data$confirmPassword;if(data.firstName===profile.firstName){delete data.firstName;}if(data.lastName===profile.lastName){delete data.lastName;}if(((_data$nickname=data.nickname)===null||_data$nickname===void 0?void 0:_data$nickname.length)===0||data.nickname===profile.nickname){delete data.nickname;}if(data.hideEmail===profile.hideEmail){delete data.hideEmail;}if(((_data$password=data.password)===null||_data$password===void 0?void 0:_data$password.length)===0||((_data$confirmPassword=data.confirmPassword)===null||_data$confirmPassword===void 0?void 0:_data$confirmPassword.length)===0){delete data.password;delete data.confirmPassword;}if(JSON.stringify(data)==='{}'){return cancel();}else{return store.updateProfileFromAPI(data);}};return/*#__PURE__*/_jsxs(\"div\",{className:\"changeProfile\",children:[/*#__PURE__*/_jsx(Typography,{className:\"changeProfile__title\",variant:\"h4\",component:\"div\",children:\"\\u0418\\u0437\\u043C\\u0435\\u043D\\u0435\\u043D\\u0438\\u0435 \\u043F\\u0440\\u043E\\u0444\\u0438\\u043B\\u044F\"}),/*#__PURE__*/_jsxs(\"form\",{className:\"changeProfile__form\",onSubmit:handleSubmit(onSubmit),children:[/*#__PURE__*/_jsx(Controller,{control:control,name:\"nickname\",defaultValue:fieldDefaultNickName,rules:nicknameChangeValidation,render:function render(_ref2){var _errors$nickname,_errors$nickname2;var field=_ref2.field;return/*#__PURE__*/_jsx(TextField,{label:\"\\u041F\\u0441\\u0435\\u0432\\u0434\\u043E\\u043D\\u0438\\u043C\",className:\"changeProfile__form-field\",InputProps:{endAdornment:/*#__PURE__*/_jsx(AlternateEmailOutlinedIcon,{className:styles.formIcon})},onChange:function onChange(e){field.onChange(e);setFieldDefaultNickName(field.value||'');},value:field.value||fieldDefaultNickName,fullWidth:true,size:\"small\",margin:\"normal\",type:\"text\",error:!!((_errors$nickname=errors.nickname)!==null&&_errors$nickname!==void 0&&_errors$nickname.message),helperText:(_errors$nickname2=errors.nickname)===null||_errors$nickname2===void 0?void 0:_errors$nickname2.message});}}),/*#__PURE__*/_jsx(Controller,{control:control,name:\"firstName\",defaultValue:fieldDefaultFirstName,rules:firstNameChangeValidation,render:function render(_ref3){var _errors$firstName,_errors$firstName2;var field=_ref3.field;return/*#__PURE__*/_jsx(TextField,{label:\"\\u0418\\u043C\\u044F\",InputProps:{endAdornment:/*#__PURE__*/_jsx(BadgeOutlinedIcon,{className:styles.formIcon})},onChange:function onChange(e){field.onChange(e);setFieldDefaultFirstName(field.value||'');},value:field.value||fieldDefaultFirstName,fullWidth:true,size:\"small\",margin:\"normal\",type:\"text\",error:!!((_errors$firstName=errors.firstName)!==null&&_errors$firstName!==void 0&&_errors$firstName.message),helperText:(_errors$firstName2=errors.firstName)===null||_errors$firstName2===void 0?void 0:_errors$firstName2.message});}}),/*#__PURE__*/_jsx(Controller,{control:control,name:\"lastName\",defaultValue:fieldDefaultLastName,rules:lastNameChangeValidation,render:function render(_ref4){var _errors$lastName,_errors$lastName2;var field=_ref4.field;return/*#__PURE__*/_jsx(TextField,{label:\"\\u0424\\u0430\\u043C\\u0438\\u043B\\u0438\\u044F\",InputProps:{endAdornment:/*#__PURE__*/_jsx(BadgeOutlinedIcon,{className:styles.formIcon})},onChange:function onChange(e){field.onChange(e);setFieldDefaultLastName(field.value||'');},value:field.value||fieldDefaultLastName,fullWidth:true,size:\"small\",margin:\"normal\",type:\"text\",error:!!((_errors$lastName=errors.lastName)!==null&&_errors$lastName!==void 0&&_errors$lastName.message),helperText:(_errors$lastName2=errors.lastName)===null||_errors$lastName2===void 0?void 0:_errors$lastName2.message});}}),/*#__PURE__*/_jsx(Controller,{control:control,name:\"password\",rules:passwordChangeValidation,render:function render(_ref5){var _errors$password,_errors$password2;var field=_ref5.field;return/*#__PURE__*/_jsx(TextField,{label:\"\\u041F\\u0430\\u0440\\u043E\\u043B\\u044C\",InputProps:{endAdornment:/*#__PURE__*/_jsx(VpnKeyOutlinedIcon,{className:styles.formIcon})},onChange:function onChange(e){return field.onChange(e);},value:field.value||'',fullWidth:true,size:\"small\",margin:\"normal\",type:\"password\",autoComplete:\"off\",helperText:(_errors$password=errors.password)===null||_errors$password===void 0?void 0:_errors$password.message,error:!!((_errors$password2=errors.password)!==null&&_errors$password2!==void 0&&_errors$password2.message)});}}),/*#__PURE__*/_jsx(Controller,{control:control,name:\"confirmPassword\"// @ts-ignore\n,rules:confirmChangePassword(watch('password'),watch('confirmPassword')),render:function render(_ref6){var _errors$confirmPasswo,_errors$confirmPasswo2;var field=_ref6.field;return/*#__PURE__*/_jsx(TextField,{label:\"\\u041F\\u043E\\u0432\\u0442\\u043E\\u0440\\u0438\\u0442\\u0435 \\u043F\\u0430\\u0440\\u043E\\u043B\\u044C\",InputProps:{endAdornment:/*#__PURE__*/_jsx(VpnKeyOutlinedIcon,{className:styles.formIcon})},onChange:function onChange(e){return field.onChange(e);},value:field.value||'',fullWidth:true,size:\"small\",margin:\"normal\",type:\"password\",autoComplete:\"off\",helperText:(_errors$confirmPasswo=errors.confirmPassword)===null||_errors$confirmPasswo===void 0?void 0:_errors$confirmPasswo.message,error:!!((_errors$confirmPasswo2=errors.confirmPassword)!==null&&_errors$confirmPasswo2!==void 0&&_errors$confirmPasswo2.message)});}}),/*#__PURE__*/_jsx(Controller,{control:control,name:\"hideEmail\",defaultValue:switchEmail,render:function render(_ref7){var field=_ref7.field;return/*#__PURE__*/_jsxs(\"div\",{className:\"changeProfile__form-switchLabel\",children:[/*#__PURE__*/_jsx(Switch,{onChange:function onChange(e){field.onChange(e);setSwitchEmail(!switchEmail);},value:switchEmail,checked:field.value||switchEmail}),switchEmail&&/*#__PURE__*/_jsx(\"label\",{children:\"\\u0414\\u0435\\u043B\\u0430\\u0435\\u0442 Email \\u0441\\u043A\\u0440\\u044B\\u0442\\u044B\\u043C \\u0434\\u043B\\u044F \\u043F\\u043E\\u043B\\u044C\\u0437\\u043E\\u0432\\u0430\\u0442\\u0435\\u043B\\u0435\\u0439\"})||/*#__PURE__*/_jsx(\"label\",{children:\"\\u0414\\u0435\\u043B\\u0430\\u0435\\u0442 Email \\u0432\\u0438\\u0434\\u0438\\u043C\\u044B\\u043C \\u0434\\u043B\\u044F \\u043F\\u043E\\u043B\\u044C\\u0437\\u043E\\u0432\\u0430\\u0442\\u0435\\u043B\\u0435\\u0439\"})]});}}),/*#__PURE__*/_jsxs(\"div\",{className:\"changeProfile__form-groupButton\",children:[/*#__PURE__*/_jsx(Button,{fullWidth:false,text:'Вернуться',callback:handleSubmit(cancel)}),/*#__PURE__*/_jsx(Button,{fullWidth:false,text:'Применить изменения',customClassName:\"messenger__sidebar-profileControl-changeProfile\"})]})]})]});};export default observer(ChangeProfileForm);","map":{"version":3,"names":["React","Controller","useForm","useFormState","nicknameChangeValidation","firstNameChangeValidation","lastNameChangeValidation","passwordChangeValidation","confirmChangePassword","Typography","TextField","AlternateEmailOutlinedIcon","VpnKeyOutlinedIcon","Button","Switch","BadgeOutlinedIcon","Context","observer","styles","ChangeProfileForm","profile","cancel","useContext","store","handleSubmit","control","watch","errors","useState","switchEmail","setSwitchEmail","nickname","fieldDefaultNickName","setFieldDefaultNickName","firstName","fieldDefaultFirstName","setFieldDefaultFirstName","lastName","fieldDefaultLastName","setFieldDefaultLastName","useEffect","hideEmail","onSubmit","data","length","password","confirmPassword","JSON","stringify","updateProfileFromAPI","field","endAdornment","formIcon","e","onChange","value","message"],"sources":["/Users/poppie/Desktop/development/messenger/app/frontend/src/modules/ChangeProfileForm/components/ChangeProfileForm.tsx"],"sourcesContent":["import React from 'react';\nimport ProfileRequest from \"../../../models/request/ProfileRequest\";\nimport {UserListItem} from \"../../../models/response/UserListItem\";\nimport {Controller, SubmitHandler, useForm, useFormState} from \"react-hook-form\";\nimport {\n    nicknameChangeValidation,\n    firstNameChangeValidation,\n    lastNameChangeValidation,\n    passwordChangeValidation,\n    confirmChangePassword,\n} from '../../validation';\nimport Typography from \"@mui/material/Typography\";\nimport TextField from \"@mui/material/TextField\";\nimport AlternateEmailOutlinedIcon from \"@mui/icons-material/AlternateEmailOutlined\";\nimport VpnKeyOutlinedIcon from \"@mui/icons-material/VpnKeyOutlined\";\nimport Button from \"../../../components/Button\";\nimport Switch from '@mui/material/Switch';\nimport BadgeOutlinedIcon from '@mui/icons-material/BadgeOutlined';\nimport {Context} from \"../../../index\";\nimport {observer} from \"mobx-react-lite\";\nimport styles from \"../../Form.module.scss\";\nimport \"./ChangeProfileForm.scss\";\n\nconst ChangeProfileForm = ({profile, cancel}: {profile: UserListItem, cancel: () => void}) => {\n    const {store} = React.useContext(Context);\n    const {handleSubmit, control, watch} = useForm<ProfileRequest>();\n    const {errors} = useFormState({control});\n    const [switchEmail, setSwitchEmail] = React.useState<boolean>(false);\n    const [fieldDefaultNickName, setFieldDefaultNickName] = React.useState<string>(profile.nickname);\n    const [fieldDefaultFirstName, setFieldDefaultFirstName] = React.useState<string>(profile.firstName || '');\n    const [fieldDefaultLastName, setFieldDefaultLastName] = React.useState<string>(profile.lastName || '');\n\n    React.useEffect(() => {\n        profile.hideEmail && setSwitchEmail(profile.hideEmail);\n    }, [profile]);\n\n    const onSubmit: SubmitHandler<ProfileRequest> = (data) => {\n        if (data.firstName === profile.firstName) {\n            delete data.firstName;\n        }\n        if (data.lastName === profile.lastName) {\n            delete data.lastName;\n        }\n        if (data.nickname?.length === 0 || data.nickname === profile.nickname) {\n            delete data.nickname;\n        }\n        if (data.hideEmail === profile.hideEmail) {\n            delete data.hideEmail;\n        }\n        if (data.password?.length === 0 || data.confirmPassword?.length === 0) {\n            delete data.password;\n            delete data.confirmPassword;\n        }\n        if (JSON.stringify(data) === '{}') {\n            return cancel();\n        } else {\n            return store.updateProfileFromAPI(data);\n        }\n    };\n\n    return (\n        <div className='changeProfile'>\n            <Typography className='changeProfile__title' variant=\"h4\" component=\"div\">\n                Изменение профиля\n            </Typography>\n\n            <form className='changeProfile__form' onSubmit={handleSubmit(onSubmit)}>\n                <Controller\n                    control={control}\n                    name=\"nickname\"\n                    defaultValue={fieldDefaultNickName}\n                    rules={nicknameChangeValidation}\n                    render={({ field }) => (\n                        <TextField\n                            label=\"Псевдоним\"\n                            className=\"changeProfile__form-field\"\n                            InputProps={{\n                                endAdornment: (\n                                    <AlternateEmailOutlinedIcon className={styles.formIcon}/>\n                                ),\n                            }}\n                            onChange={(e) => {\n                                field.onChange(e);\n                                setFieldDefaultNickName(field.value || '');\n                            }}\n                            value={field.value || fieldDefaultNickName}\n                            fullWidth={ true }\n                            size=\"small\"\n                            margin=\"normal\"\n                            type=\"text\"\n                            error={!!errors.nickname?.message}\n                            helperText={errors.nickname?.message}\n                        />\n                    )}\n                />\n                <Controller\n                    control={control}\n                    name=\"firstName\"\n                    defaultValue={fieldDefaultFirstName}\n                    rules={firstNameChangeValidation}\n                    render={({ field }) => (\n                        <TextField\n                            label=\"Имя\"\n                            InputProps={{\n                                endAdornment: (\n                                    <BadgeOutlinedIcon className={styles.formIcon}/>\n                                ),\n                            }}\n                            onChange={(e) => {\n                                field.onChange(e);\n                                setFieldDefaultFirstName(field.value || '');\n                            }}\n                            value={field.value || fieldDefaultFirstName}\n                            fullWidth={ true }\n                            size=\"small\"\n                            margin=\"normal\"\n                            type=\"text\"\n                            error={!!errors.firstName?.message}\n                            helperText={errors.firstName?.message}\n                        />\n                    )}\n                />\n                <Controller\n                    control={control}\n                    name=\"lastName\"\n                    defaultValue={fieldDefaultLastName}\n                    rules={lastNameChangeValidation}\n                    render={({ field }) => (\n                        <TextField\n                            label=\"Фамилия\"\n                            InputProps={{\n                                endAdornment: (\n                                    <BadgeOutlinedIcon className={styles.formIcon}/>\n                                ),\n                            }}\n                            onChange={(e) => {\n                                field.onChange(e);\n                                setFieldDefaultLastName(field.value || '');\n                            }}\n                            value={field.value || fieldDefaultLastName}\n                            fullWidth={ true }\n                            size=\"small\"\n                            margin=\"normal\"\n                            type=\"text\"\n                            error={!!errors.lastName?.message}\n                            helperText={errors.lastName?.message}\n                        />\n                    )}\n                />\n                <Controller\n                    control={control}\n                    name=\"password\"\n                    rules={passwordChangeValidation}\n                    render={({ field }) => (\n                        <TextField\n                            label=\"Пароль\"\n                            InputProps={{\n                                endAdornment: (\n                                    <VpnKeyOutlinedIcon className={styles.formIcon}/>\n                                ),\n                            }}\n                            onChange={(e) => field.onChange(e)}\n                            value={field.value || ''}\n                            fullWidth={ true }\n                            size=\"small\"\n                            margin=\"normal\"\n                            type=\"password\"\n                            autoComplete=\"off\"\n                            helperText={errors.password?.message}\n                            error={!!errors.password?.message}\n                        />\n                    )}\n                />\n                <Controller\n                    control={control}\n                    name=\"confirmPassword\"\n                    // @ts-ignore\n                    rules={confirmChangePassword(watch('password'), watch('confirmPassword'))}\n                    render={({ field }) => (\n                        <TextField\n                            label=\"Повторите пароль\"\n                            InputProps={{\n                                endAdornment: (\n                                    <VpnKeyOutlinedIcon className={styles.formIcon}/>\n                                ),\n                            }}\n                            onChange={(e) => field.onChange(e)}\n                            value={field.value || ''}\n                            fullWidth={ true }\n                            size=\"small\"\n                            margin=\"normal\"\n                            type=\"password\"\n                            autoComplete=\"off\"\n                            helperText={errors.confirmPassword?.message}\n                            error={!!errors.confirmPassword?.message}\n                        />\n                    )}\n                />\n                <Controller\n                    control={control}\n                    name=\"hideEmail\"\n                    defaultValue={switchEmail}\n                    render={({ field }) => (\n                        <div className=\"changeProfile__form-switchLabel\">\n                            <Switch\n                                onChange={(e) => {\n                                    field.onChange(e);\n                                    setSwitchEmail(!switchEmail);\n                                }}\n                                value={switchEmail}\n                                checked={field.value || switchEmail}\n                            />\n                            {(switchEmail &&\n                                <label>Делает Email скрытым для пользователей</label>\n                            ) ||\n                                <label>Делает Email видимым для пользователей</label>\n                            }\n                        </div>\n                    )}\n                />\n                <div className=\"changeProfile__form-groupButton\">\n                    <Button\n                        fullWidth={false}\n                        text={'Вернуться'}\n                        callback={handleSubmit(cancel)}\n                    />\n                    <Button\n                        fullWidth={false}\n                        text={'Применить изменения'}\n                        customClassName=\"messenger__sidebar-profileControl-changeProfile\"\n                    />\n                </div>\n            </form>\n        </div>\n    );\n}\n\nexport default observer(ChangeProfileForm);"],"mappings":"8IAAA,MAAOA,MAAK,KAAM,OAAO,CAGz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